package com.xiao.springaopdemo1;

import com.xiao.springaopdemo1.annnotation.CalculatorOne;
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

@SpringBootTest
public class loggAspectOne {
    @Test
    public void around(){
       ApplicationContext ioc = new ClassPathXmlApplicationContext("AOPMethod.xml");
        CalculatorOne bean = ioc.getBean(CalculatorOne.class);
        int div = bean.add(1, 0);
        System.out.println(div);

    }
}
